FROM java:8
MAINTAINER hp huangpeng@ruirenyun.com
VOLUME /easy-code/logs
ENV TZ=Asia/Shanghai JAVA_OPTS="-server -Xms256m -Xmx256m -Xmn64m -Xss512k \
-XX:MetaspaceSize=128m -XX:MaxMetaspaceSize=128m -XX:-OmitStackTraceInFastThrow \
-XX:+HeapDumpOnOutOfMemoryError -XX:HeapDumpPath=/recruit-mapi/logs/java_heapdump.hprof -XX:-UseLargePages"
COPY target/*.jar app.jar
RUN ln -snf /usr/share/zoneinfo/$TZ /etc/localtime && echo $TZ > /etc/timezone
EXPOSE 18002
EXPOSE 18003
ENTRYPOINT [ "sh", "-c", "java $JAVA_OPTS -Djava.security.egd=file:/dev/./urandom \
-agentlib:jdwp=transport=dt_socket,server=y,suspend=n,address=18003 \
-jar ./app.jar" ]
ENV LANG C.UTF-8